﻿$(function () {    
    $('#btnSearch').click(function () {
        search();
    });
    var year = new Date().getFullYear();
    var month = new Date().getMonth() + 1;
    $("#txtDate").val("2018-11-01 08:00");
    $('#btnSearch').click();
});
function search(pageNumber) {
    var queryData = {
        date: $("#txtDate").val(),
        triageId: $("#txtPName").val(),
        typecode: $("#txtDoctorAdviceType").val(),
        effectFlg: $("#txtExceReuslt").val(),
    }
    initTable(queryData, 1);
}
function initTable(queryData, pageNumber) {
    $("#maingrid").ligerGrid({
        checkbox: false,
        height: '100%',
        url: '/StrokeCenter/DoctorAdvice/Search?ram=' + new Date().getMilliseconds(),
        parms: queryData,
        page: pageNumber,
        pageSize: 30,
        rownumbers: false,
        heightDiff: -5,
        columns: [
{ display: '时间', name: '', minWidth: 50 },
{ display: '医生', name: '', minWidth: 50 },
{ display: '医嘱', name: '', minWidth: 50 },
{ display: '规格', name: '', minWidth: 50 },
{ display: '用量', name: '', minWidth: 50 },
{ display: '用量单位', name: '', minWidth: 50 },
{ display: '频次', name: '', minWidth: 50 },
{ display: '用法', name: '', minWidth: 50 },
{ display: '执行情况', name: '', minWidth: 50 },
{ display: '执行开始时间', name: '', minWidth: 50 },
{ display: '执行结束时间', name: '', minWidth: 50 },
{ display: '执行开始人', name: '', minWidth: 50 },
{ display: '执行结束人', name: '', minWidth: 50 }
        ],
        isScroll: true        
    });
}